﻿<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ taglib prefix="sec" uri="http://www.springframework.org/security/tags" %>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt"%>

<fmt:setBundle basename="ApplicationMessage" />
<fmt:setLocale value="zh_CN" />

<!DOCTYPE html>
<html lang="zh-CN">
<head>

  <%@ include file="/WEB-INF/include/meta.jsp"%>
  <%@ include file="/WEB-INF/include/css.jsp"%>

</head>

<body>

  <%@ include file="/WEB-INF/include/header.jsp"%>
  
  <%@ include file="/WEB-INF/include/menu.jsp"%>

  <div class="container main-content">

    <div class="panel panel-default x-panel x-panel-layout">
      
      <div class="panel-heading">
        <ol class="breadcrumb clearfix">
          <li><a href="${ctx.host}/system">系统管理</a></li>
          <li class="active">门店管理</li>
          <li class="no-before pull-right" style="min-width: 65px;">
            <a onclick="window.history.back();"><i class="glyphicon glyphicon-arrow-left"></i>&nbsp;&nbsp;返回</a>
          </li>
        </ol>
      </div>

      <div class="panel-body">

        <div class="col-xs-2 x-panel-layout-left no-horizontal-padding">
          <%@ include file="/WEB-INF/include/submenu.jsp"%>
        </div>

        <div class="col-xs-10 x-panel-layout-right">

          <div class="x-breadcrumb-wrapper">
            <div class="x-breadcrumb clearfix">
              <h2><i class="glyphicon glyphicon-fire"></i>&nbsp;&nbsp;<span>门店管理&nbsp;-&nbsp;门店详情</span></h2>
            </div>
          </div>
          
          <div class="x-breadcrumb-wrapper">
          
            <div class="x-breadcrumb-wrapper top-margin-20" style="position: relative;">
              <ul class="nav nav-pills x-breadcrumb-nav ajax-tab" data-content="#basic-content" data-operation="#site-operation">
                <li class="pull-left active">
                  <a id="info" href="${ctx.host}/sites/${site.id}" data-toggle="tab" data-target="#site-info">基本信息</a>
                </li>
                <li class="pull-left">
                  <a id="hour" href="${ctx.host}/sites/${site.id}/business-hour" data-toggle="tab" data-target="#site-hour">营业时间</a>
                </li>
              </ul>
              <div id="site-operation" class="tab-operations pull-right">
                <div id="info-operation" class="tab-operations hide">
                  <a href="${ctx.host}/sites/${site.id}/edit-roomlimit" data-target="#edit-roomLimit" data-toggle="modal" class="hover-no-text-decoration" style="position: absolute; right: 0px; top: 0px; margin-top: 10px; margin-right: 150px;" title="编辑容量">编辑容量</a>
                  <a href="${ctx.host}/sites/${site.id}/edit-room-description" data-target="#edit-room-description" data-toggle="modal" class="hover-no-text-decoration" style="position: absolute; right: 0px; top: 0px; margin-top: 10px; margin-right: 80px;" title="区域描述">区域描述</a>
                  <a href="${ctx.host}/sites/${site.id}/edit" data-target="#edit-site" data-toggle="modal" class="hover-no-text-decoration" style="position: absolute; right: 0px; top: 0px; margin-top: 10px; margin-right: 10px;" title="编辑信息">编辑信息</a>
                </div>
                <div id="hour-operation" class="tab-operations hide">
                  <a href="${ctx.host}/sites/${site.id}/edit-business-hour" data-target="#edit-business-hour" data-toggle="modal" class="hover-no-text-decoration" style="position: absolute; right: 0px; top: 0px; margin-top: 10px; margin-right: 10px;" title="编辑营业时间">编辑营业时间</a>
                </div>
              </div>
              
            </div>
          
            <div id="basic-content" class="tab-content ajax-tab-content">
              <div class="tab-pane fade active in" id="site-info" style="min-height: 100px;">
                <div class="form-horizontal bottom-margin-20" style="margin-top: 20px;">
                  
                  <div class="form-group">
                    <label class="col-xs-2 control-label">门店店长：</label>
                    <div class="col-xs-4 pull-left">
                      <p class="form-control-static">${site.manager.name}</p>
                    </div>
                  </div>
                  
                  <div class="form-group">
                    <label class="col-xs-2 control-label">门店编号：</label>
                    <div class="col-xs-4 pull-left">
                      <p class="form-control-static">${site.code}</p>
                    </div>
                    
                    <label class="col-xs-2 control-label">门店名称：</label>
                    <div class="col-xs-4 pull-left">
                      <p class="form-control-static">${site.name}</p>
                    </div>
                  </div>
                  
                  <div class="form-group">
                    <label class="col-xs-2 control-label">门店别名：</label>
                    <div class="col-xs-4 pull-left">
                      <p class="form-control-static">${site.alias}</p>
                    </div>
                    <label class="col-xs-2 control-label">门店电话：</label>
                    <div class="col-xs-4 pull-left">
                      <p class="form-control-static">${site.landline}</p>
                    </div>
                  </div>
                  
                  <div class="form-group">
                    <label class="col-xs-2 control-label">所属城市：</label>
                    <div class="col-xs-4 pull-left">
                      <p class="form-control-static">${site.city}</p>
                    </div>
                    
                    <label class="control-label col-xs-2">创建时间：</label>
                    <div class="col-xs-4 pull-left">
                      <p class="form-control-static"><fmt:formatDate value="${site.createTime}" pattern="yyyy-MM-dd"/></p>
                    </div>
                  </div>
                  
                  <div class="form-group">
                    <label class="control-label col-xs-2">联系人姓名：</label>
                    <div class="col-xs-4 pull-left">
                      <p class="form-control-static">${site.contact.contactPerson}</p>
                    </div>
                    
                    <label class="control-label col-xs-2">联系人号码：</label>
                    <div class="col-xs-4 pull-left">
                      <p class="form-control-static">${site.contact.contactPhone}</p>
                    </div> 
                  </div>
                  
                  <div class="form-group">
                    <label class="control-label col-xs-2">公共区域容量：</label>
                    <div class="col-xs-4 pull-left">
                      <p class="form-control-static">${site.roomLimit.commonLimit}</p>
                    </div>
                    
                    <label class="control-label col-xs-2">私有区域容量：</label>
                    <div class="col-xs-4 pull-left">
                      <p class="form-control-static">${site.roomLimit.roomLimit}</p>
                    </div> 
                  </div>
                  
                  <div class="form-group">
                    <label class="control-label col-xs-2">公共区域描述：</label>
                    <div class="col-xs-4 pull-left">
                      <p class="form-control-static">${site.roomLimit.commonDescription}</p>
                    </div>
                    
                    <label class="control-label col-xs-2">私有区域描述：</label>
                    <div class="col-xs-4 pull-left">
                      <p class="form-control-static">${site.roomLimit.roomDescription}</p>
                    </div>
                  </div>
                  
                  <div class="form-group">
                    <label class="control-label col-xs-2">门店地址：</label>
                    <div class="col-xs-4 pull-left">
                      <p class="form-control-static">${site.location.address}&nbsp;&nbsp;(${site.location.addressDescription})</p>
                    </div>
                  </div>
                  
                </div>
              </div>
            </div>
          
          </div>
          
        </div>

      </div>
      
    </div>
    
  </div>

  <%@ include file="/WEB-INF/include/script.jsp"%>
  
  <d:resource root="${ctx.resource}" type="script" src="js/page/system/site/site-view.js">
    <script type="text/javascript">
      require(['page/system/site/site-view'] , function(page){
        page.init();
      })
    </script>
  </d:resource>
  
</body>

</html>